import { createRouter, createWebHistory } from 'vue-router'
import HomeView from '@/views/home.vue'
const router = createRouter({
  history: createWebHistory(import.meta.env.BASE_URL),
  routes: [
    {
      path: '/',
      name: 'home',
      component: HomeView
    },
    {
      path: '/authentication',
      name: '企业信用认证首页',
      component: () => import('@/views/authentication/index.vue')
    },
    {
      path: "/selectType",
      name: '企业信用认证选择类型',
      component: () => import('@/views/authentication/selectType.vue')
    },
    {
      path: "/flow1",
      name: '企业信用认证流程一',
      component: () => import('@/views/authentication/flow/flow1.vue')
    },
    {
      path: "/flow2",
      name: '企业信用认证流程二',
      component: () => import('@/views/authentication/flow/flow2.vue')
    },
    {
      path: "/flow3",
      name: '企业信用认证流程三',
      component: () => import('@/views/authentication/flow/flow3.vue')
    },
    {
      path: "/flow4",
      name: '企业信用认证流程四',
      component: () => import('@/views/authentication/flow/flow4.vue')
    },
    {
      path: "/flow5",
      name: '企业信用认证流程五',
      component: () => import('@/views/authentication/flow/flow5.vue')
    },
    {
      path: "/flow5-1",
      name: '企业信用认证流程五1',
      component: () => import('@/views/authentication/flow/flow5-1.vue')
    },
    {
      path: "/flow6",
      name: '企业信用认证流程六',
      component: () => import('@/views/authentication/flow/flow6.vue')
    },
    {
      path: "/flow7",
      name: '企业信用认证流程七',
      component: () => import('@/views/authentication/flow/flow7.vue')
    },
    {
      path: "/flow8",
      name: '企业信用认证流程八',
      component: () => import('@/views/authentication/flow/flow8.vue')
    },
    // 信用报告查询
    {
      path: "/report",
      name: '信用报告查询',
      component: () => import('@/views/report/index.vue')
    },
    {
      path: "/getReport",
      name: '获取报告',
      component: () => import('@/views/report/getReport.vue')
    },
    {
      path: "/submit",
      name: '提交',
      component: () => import('@/views/report/submit.vue')
    },
    {
      path: '/brran/riskqueryind',
      name: '企业风险扫描',
      component: () => import('../views/brran/riskqueryind/index.vue')
    },
    {
      path: "/brran/riskDetails",
      name: '企业风险扫描详情',
      component: () => import('@/views/brran/riskqueryind/riskDetails.vue')
    },
    // 信用信息查询
    {
      path: "/query/index",
      name: '信用信息查询首页',
      component: () => import('@/views/query/index.vue')
    },
    {
      path: "/query",
      name: '信用信息查询',
      component: () => import('@/views/query/query.vue')
    },
    {
      path: "/advancedQuery",
      name: '高级查询1',
      component: () => import('@/views/query/advancedQuery.vue')
    },
    {
      path: "/advanced",
      name: '高级查询结果',
      component: () => import('@/views/query/advanced.vue')
    },
    {
      path: "/dem",
      name: '高级查询',
      component: () => import('@/views/dem.vue')
    },
    // 用户中心
    {
      path: '/user',
      name: '用户中心',
      redirect: "/myReport",
      meta: {
        title: "数字金融服务平台-商驿科技",
      },
      component: () => import('@/views/userCenter/index.vue'),
      children: [
        {
          path: '/myReport',
          name: '我的报告',
          meta: {
            title: "数字金融服务平台-商驿科技",
          },
          component: () => import('@/views/project/myReport.vue'),
        },
        {
          path: '/myAuthentication',
          name: '我的认证',
          meta: {
            title: "数字金融服务平台-商驿科技",
          },
          component: () => import('@/views/project/myAuthentication.vue'),
        },
        {
          path: '/sweepRecord',
          name: '风险扫描记录',
          meta: {
            title: "数字金融服务平台-商驿科技",
          },
          component: () => import('@/views/project/sweepRecord.vue'),
        },
        {
          path: "/userDetails",
          name: '我的认证详情',
          meta: {
            title: "数字金融服务平台-商驿科技",
          },
          component: () => import('@/views/project/userDetails.vue'),
        },
        {
          path: "/userCenter",
          name: '我的认证详情1',
          meta: {
            title: "数字金融服务平台-商驿科技",
          },
          component: () => import('@/views/project/userCenter.vue'),
        },


      ]
    },
    {
      path: '/initial',
      name: '等等',
      meta: {
        title: "湖北国际贸易数字化平台测试版",
        index: 14,
        auth: true,
      },
      component: () => import('@/views/result/initial.vue'),
    },
    {
      path: '/gain',
      name: '等一等',
      meta: {
        title: "湖北国际贸易数字化平台测试版",
        index: 14,
        auth: true,
      },
      component: () => import('@/views/result/gain.vue'),
    },
  ]
})

export default router
